#include "../include/stu.h"

void manage_c(){
    system("clear");
    int n;
	while(n){
		printf("1：新增课程\n");
		printf("2：修改课程\n");
		printf("3：删除课程\n");
		printf("4：根据课程号查看课程\n");
		printf("5：根据课程名查看课程\n");
		printf("6：查看所有课程\n");
		printf("7：退出\n\n");
		scanf("%d",&n);
		switch (n)
		{
		case (1): {
			insert_c();
			break;
		}
		case (2): {
			change_c();
			break;
		}
		case (3): {
			delete_c();
			break;
		}
		case (4): {
			findbyid_c();
			break;
		}
		case (5): {
			findbyname_c();
			break;
		}
		case (6): {
			show_c();
			break;
		}
		default:
			break;
		}
		if(n == 7) break;
	}
}
